package org.learn.file;

import java.io.BufferedWriter;
import java.io.FileWriter;
import java.io.IOException;

public class BufferedWriter_ {
    public static void main(String[] args) throws IOException {
        String filePath = "d:\\a.txt";
        //创建对象
        BufferedWriter bufferedWriter = new BufferedWriter(new FileWriter(filePath,true));
        bufferedWriter.write("hello,韩顺平教育");
        //插入一个换行
        bufferedWriter.newLine();//系统相关的换行
        //关外层
        bufferedWriter.close();
    }

}
